import service from '@/util/request.js';

const defaultPrefix = '/videos';

export function getVideoListService(videoQuery) {
  return service.post(defaultPrefix + '/list', videoQuery);
}

export function addVideoService(video) {
  return service.post(defaultPrefix, video);
}

export function updateVideoService(video) {
  return service.put(defaultPrefix, video);
}

export function deleteVideoService(videoId) {
  return service.delete(defaultPrefix + '/' + videoId);
}